package persistence;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;


public class Conexao {

	private static final String DRIVER = "com.mysql.jdbc.Driver";
	private static final String URL = "jdbc:mysql://localhost/estoque";
	private static final String USER = "root";
	private static final String SENHA = "";
	
	
public static  Connection getConnection(){
	try {
		Class.forName(DRIVER);
		return DriverManager.getConnection(URL, USER, SENHA);
	} catch (ClassNotFoundException e1) {
	}catch (SQLException e) {
		System.out.println("error");
	}
	return null;
}	
}
